//École de Technologie Supérieure (ÉTS)
//LOG720 - Laboratoire 3  - Intégration de Spring + Hibernate
//Date de remise: 2011-12-13
//Auteurs:
//Jonathan Aubuchon (AUBJ18038704)
//Jeff Grenier (GREJ02098703)
//Francis Paré (PARF21038708)

package springapp.web;

import java.util.HashMap;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.Controller;

import springapp.service.DossierManager;

public class ConsulterDossiersController implements Controller {

	public ModelAndView handleRequest(HttpServletRequest arg0,
			HttpServletResponse arg1) throws Exception {
		
		Map<String, Object> myModel = new HashMap<String, Object>();
		
		myModel.put("dossiers", DossierManager.getInstance().getDossiers());

		return new ModelAndView("Dossiers", "model", myModel);
	}

}
